package com.mybatis.dome;

import com.mybatis.io.Resources;
import com.mybatis.sqlSession.SqlSession;
import com.mybatis.sqlSession.SqlSessionFactory;
import com.mybatis.sqlSession.SqlSessionFactoryBuilder;
import org.dom4j.DocumentException;

import java.beans.PropertyVetoException;
import java.io.InputStream;
import java.util.List;

public class Test {
    public static void main(String[] args) {
        try{
            IUserDao dao = new IUserDaoImpl();
            User user = new User();
            user.setId(1);
            user.setUsername("温冬鹏");
            User user1 = dao.selectOne(user);
            System.out.println(user1);
//            List<User> users = dao.selectList();
//            for (User user : users) {
//                System.out.println(user);
//            }
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}
